<head th:fragment="head">
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <!-- Meta, title, CSS, favicons, etc. -->
    <meta charset="utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <meta name="_csrf" content="${_csrf.token}" th:content="${_csrf.token}"/>
    <!-- default header name is X-CSRF-TOKEN -->
    <meta name="_csrf_header" content="${_csrf.headerName}" th:content="${_csrf.headerName}"/>
    <link href="images/logo-left.ico" th:href="@{/images/logo-left.ico}" type="image/x-icon" rel="shortcut icon" />
    <title>智慧X平台</title>
    <!-- Bootstrap core CSS -->
    <link href="../static/bootstrap/css/bootstrap.min.css" rel="stylesheet" th:href="@{/bootstrap/css/bootstrap.min.css}"/>

    <link rel="stylesheet" href="../static/bootstrap/css/bootstrapValidator.css" th:href="@{/bootstrap/css/bootstrapValidator.css}"/>
    <!-- Font Awesome -->
    <link href="../static/css/font-awesome.min.css" rel="stylesheet" th:href="@{/css/font-awesome.min.css}"/>

    <!-- ionicons -->
    <link href="../static/css/ionicons.min.css" rel="stylesheet" th:href="@{/css/ionicons.min.css}"/>

    <!-- Morris -->
    <link href="../static/css/morris.css" rel="stylesheet" th:href="@{/css/morris.css}"/>

    <!-- Datepicker -->
    <link href="../static/css/datepicker.css" rel="stylesheet" th:href="@{/css/datepicker.css}"/>

    <!-- Animate -->
    <link href="../static/css/animate.min.css" rel="stylesheet" th:href="@{/css/animate.min.css}">

    <!-- Owl Carousel -->
    <link href="../static/css/owl.carousel.min.css" rel="stylesheet" th:href="@{/css/owl.carousel.min.css}">
    <link href="../static/css/owl.theme.default.min.css" rel="stylesheet" th:href="@{/css/owl.theme.default.min.css}">

    <!-- Simplify -->
    <link href="../static/css/simplify.min.css" rel="stylesheet" th:href="@{/css/simplify.min.css}"/>
    <!--ztree-->
    <link rel="stylesheet" href="../static/ztree/css/demo.css" th:href="@{/ztree/css/demo.css}">
    <link rel="stylesheet" href="../static/ztree/css/zTreeStyle.css" th:href="@{/ztree/css/zTreeStyle.css}">
    <!--初始化字体-->
    <link rel="stylesheet" href="../static/css/Initialization.css" th:href="@{/css/Initialization.css}"/>

    <!--角色样式-->
    <link rel="stylesheet" href="../static/css/role.css" th:href="@{/css/role.css}"/>

</head>

<footer th:fragment="footer">
    <script src="../static/js/jquery-1.11.1.min.js" th:src="@{/js/jquery-1.11.1.min.js}"></script>

    <!-- Bootstrap -->
    <script src="../static/bootstrap/js/bootstrap.min.js" th:src="@{/bootstrap/js/bootstrap.min.js}"></script>
    <script src="../static/bootstrap/js/bootstrapValidator.js" th:src="@{/bootstrap/js/bootstrapValidator.js}"></script>
    <!-- Flot -->
    <!--<script src='js/jquery.flot.min.js'></script>-->

    <!-- Slimscroll -->
    <script src='../static/js/jquery.slimscroll.min.js' th:src="@{/js/jquery.slimscroll.min.js}"></script>

    <!-- Morris -->
    <script src='../static/js/rapheal.min.js' th:src="@{/js/rapheal.min.js}"></script>
    <script src='../static/js/morris.min.js' th:src="@{/js/morris.min.js}"></script>

    <!-- Datepicker -->
    <script src='../static/js/uncompressed/datepicker.js' th:src="@{/js/uncompressed/datepicker.js}"></script>

    <!-- Sparkline -->
    <script src='../static/js/sparkline.min.js' th:src="@{/js/sparkline.min.js}"></script>

    <!-- Skycons -->
    <script src='../static/js/uncompressed/skycons.js' th:src="@{/js/uncompressed/skycons.js}"></script>

    <!-- Popup Overlay -->
    <script src='../static/js/jquery.popupoverlay.min.js' th:src="@{/js/jquery.popupoverlay.min.js}"></script>

    <!-- Easy Pie Chart -->
    <script src='../static/js/jquery.easypiechart.min.js' th:src="@{/js/jquery.easypiechart.min.js}"></script>

    <!-- Sortable -->
    <script src='../static/js/uncompressed/jquery.sortable.js' th:src="@{/js/uncompressed/jquery.sortable.js}"></script>

    <!-- Owl Carousel -->
    <script src='../static/js/owl.carousel.min.js' th:src="@{/js/owl.carousel.min.js}"></script>

    <!-- Modernizr -->
    <script src='../static/js/modernizr.min.js' th:src="@{/js/modernizr.min.js}"></script>

    <!-- Simplify -->
    <script src="../static/js/simplify/simplify.js" th:src="@{/js/simplify/simplify.js}"></script>

        <!--ztree-->
    <script src="../static/ztree/js/jquery.ztree.core.js" th:src="@{/ztree/js/jquery.ztree.core.js}"></script>
    <script src="../static/ztree/js/jquery.ztree.excheck.js" th:src="@{/ztree/js/jquery.ztree.excheck.js}"></script>
    <!--粒子背景-->
    <script src="../static/js/jquery.particleground.min.js" th:src="@{/js/jquery.particleground.min.js}"></script>
    <script src="../static/js/demo.js" th:src="@{/js/demo.js}"></script>
    <script type="text/javascript" th:inline="javascript">

        function tagscheck(a) {
            var lng = document.getElementsByTagName("tr").length;
            for (i = 0; i < lng; i++) {
                var temp = document.getElementsByTagName("tr")[i];
                if (a == temp) {
                    temp.style.background = "#f0faf8";
                } else {
                    temp.style.background = "";
                }

            }

        }
        $(function()	{
//            $("tbody tr").hover(function(){
//                $(this).css("background-color","#f9f9f9");
//            });
//            $("tbody tr").click(function(){
//                $(this).css("background-color","#f0faf8");
//            });
            $('.chart').easyPieChart({
                easing: 'easeOutBounce',
                size: '140',
                lineWidth: '7',
                barColor: '#7266ba',
                onStep: function(from, to, percent) {
                    $(this.el).find('.percent').text(Math.round(percent));
                }
            });

            $('.sortable-list').sortable();

            $('.todo-checkbox').click(function()	{

                var _activeCheckbox = $(this).find('input[type="checkbox"]');

                if(_activeCheckbox.is(':checked'))	{
                    $(this).parent().addClass('selected');
                }
                else	{
                    $(this).parent().removeClass('selected');
                }

            });

            //Delete Widget Confirmation
            $('#deleteWidgetConfirm').popup({
                vertical: 'top',
                pagecontainer: '.container',
                transition: 'all 0.3s'
            });
        });
        $(function () {

        })
    </script>

    <script type="text/javascript" th:inline="javascript">
        $(function () {//ajax,提交前，请求头插入token
            /*[+
             var token = $("meta[name='_csrf']").attr("content");
             var header = $("meta[name='_csrf_header']").attr("content");
             $(document).ajaxSend(function(e, xhr, options) {
             xhr.setRequestHeader(header, token);
             });
             +]*/
        });
        $(function () {
            $(".top_nav").load(/*[[@{header}]]*/"../header.html", function (res) {
                return true;
            });

        })
        $.extend({
            goTo: function (url, data) {
                $(".right_col").load(url, data, function (res) {
                    return true;
                });
            }
        })

        /*]]>*/
    </script>

</footer>